home *** CD-ROM | disk | FTP | other *** search
/ SuperHack / SuperHack CD.bin / CODING / GRAPHICS / GMSMTH01.ZIP / INCLUDE / XFILEIO.H < prev    next >
Encoding:
C/C++ Source or Header  |  1995-04-19  |  1.8 KB  |  77 lines

  1. /*-----------------------------------------------------------------------
  2. ;
  3. ; XFILEIO - header file
  4. ;
  5. ;
  6. ;
  7. ; ****** XLIB - Mode X graphics library                ****************
  8. ; ******                                               ****************
  9. ; ****** Written By Themie Gouthas                     ****************
  10. ;
  11. ; egg@dstos3.dsto.gov.au
  12. ; teg@bart.dsto.gov.au
  13. ;
  14. ;  Terminology & notes:
  15. ;         VRAM ==   Video RAM
  16. ;         SRAM ==   System RAM
  17. ;         X coordinates are in pixels unless explicitly stated
  18. ;
  19. ;-----------------------------------------------------------------------*/
  20.  
  21. #ifndef _XFILEIO_H_
  22. #define _XFILEIO_H_
  23.  
  24. #include <g_def.h>
  25.  
  26. #define F_RDONLY  0
  27. #define F_WRONLY  1
  28. #define F_RDWR    2
  29.  
  30. #define SEEK_START 0
  31. #define SEEK_CURR  1
  32. #define SEEK_END   2
  33.  
  34. #define FILE_ERR -1
  35.  
  36. /* FUNCTIONS =========================================================== */
  37.  
  38. extern short f_open(              /* Open a file returning its handle */
  39.      char * filename,
  40.      char access);
  41.  
  42. extern short f_close(             /* Close a file  */
  43.      short handle);
  44.  
  45. extern short f_read(              /* Read a block of data from a file */
  46.      short handle,
  47.      void far * buffer,
  48.      USHORT count);
  49.  
  50. extern short f_write(             /* Write a block of data to a file */
  51.      short handle,
  52.      void far * buffer,
  53.      USHORT count);
  54.  
  55. extern long f_seek(         /* Position the file pointer */
  56.      short handle,
  57.      long position,
  58.      char method_code);
  59.  
  60. extern long f_filelength(   /* Return the length of the file */
  61.      short handle);
  62.  
  63.  
  64. extern USHORT load_size;
  65. FARPTR far_load(char *name);
  66. char *near_load(char *name);
  67. char *near_reload(char *name, BYTE *b);
  68. FARPTR far_reload(char *name, FARPTR b);
  69. short global_put_env( char *varName, char *varText );
  70.  
  71. #endif
  72.  
  73.  
  74. 
  75.  
  76.        
  77.